const db = uniCloud.database()
const dbCmd = db.command
exports.main = async (event, context) => {
	let { value } = event
  return await db.collection('article').where(dbCmd.or({
    title: new RegExp(value,'i')
  })).limit(8).orderBy("posttime","desc").get()
};
